package com.yq.core.json;

import org.slf4j.Logger;
import org.slf4j.LoggerFactory;


/**
 * 
 * 文件名: BnEmployeeController.java
 * 创建人: yinquan
 * 创建日期: 2017-03-21 15:42:34
 * 描  述: 人员信息表
 * 版本号： 1.0
 */

@SuppressWarnings({ "unused" })
public class CodCodeData {

    private static Logger logger = LoggerFactory.getLogger(CodCodeData.class);

	// 配置信息
	public static String config() {
		// 需要校验字段
		String str = "{" +
			"cd_code_insert_init:{" +
				"" +
			"}," +
			"cd_code_update_init:{" +
				"verify:{}," +
			"}," +
			"cd_code_insert_init:{" +
				"verify:{}," +
			"}," +

			"cd_code_search_load:{" +
				"code:{length:[0, 20], required:false, check:'s', mode:'like'}," + // 0-9 a-z A-Z
				"name:{length:[0, 20], required:false, check:'s', mode:'like'}," + // 0-9 a-z A-Z 中文
				"parent:{length:32, required:false, check:'s', mode:'eq'}," + // 0-9 a-z A-Z
				"deleteState:{length:1, required:false, check:'n01', mode:'eq'}," + // 0 1
			"}," +
			"cd_code_insert_exec:{" +
				"code:{length:[1, 20], required:true, check:'s'}," + // 0-9 a-z A-Z
				"name:{length:[1, 20], required:true, check:'s'}," + // 0-9 a-z A-Z 中文
				"parent:{length:32, required:false, check:'s'}," + // 0-9 a-z A-Z
				"remark:{length:[0, 200], required:false, check:'s'}," + // 0-9 a-z A-Z
			"}," +
			"cd_code_update_exec:{" +
				"verify:{}," +
			"}," +

			"cd_code_delete_exec:{" +
				"verify:{}," +
			"}," +

			"entity:{" + // 表名
				"name:'cd_code'," +
				"id:'uid'," +
				"insert:{ deleteState:'0' }," + // 新增：默认赋值字段
				"update:{}," + // 修改：默认赋值字段
				"delete:{ deleteState:'1' }," + // 删除：默认复制字段
				"ignore:{class:true}," + // 可以忽略的字段
			"}" +

		"}";

		return str;
	}
}
